package dryven.util.crypt;

import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;

public class MD5Hash extends MessageDigestHash {
	private String _value;
	
	public MD5Hash(String value) {
		super();
		_value = value;
	}

	@Override
	public String hash() {
		try {
			return processDigest(MessageDigest.getInstance("MD5"),_value);
		} catch (NoSuchAlgorithmException e) {
			throw new RuntimeException("Could not get MD5 message digest",e);
		}
	}
}
